package com.ctbri.containerindepth;

import java.util.List;

import com.ctbri.util.TextFile;


	
public class Ex19 {
	public static void main(String[] args) {
		List<String> words = new TextFile
				("D:/Java/workspace/enterprise_gateway/WebContent/rtdata.jsp", "\\W+");
		SimpleHashMap<String, Integer> map = new SimpleHashMap<>();
		for(String word : words) {
			Integer num = map.get(word);
			if(num == null)
				map.put(word, 1);
			else
				map.put(word, ++num);
		}
		System.out.println(map);
	}
}
